<?php
	$path = "../";
	include_once($path.'configuration.php');
	/*traitements*/
	include_once($path.'head.php');
?>
	<div id="bodyWrapper">
		<h1>GESTION DES TYPES D'INCIDENT !</h1>
		<a href="<?php echo $path; ?>administration/add_type_incident.php"> AJOUTER </a>
		<table>
			<tr>
				<th>
					ID
				</th>
				<th>
					Nom
				</th>
				<th>
				</th>
				<th>
				</th>
			</tr>
			<?php
				$liste = $dbh->getAllType_Incident();
				foreach($liste as $type_incident){
			?>
				<tr>
					<td>
						<?php echo $type_incident['id_type_incident']; ?>
					</td>
					<td>
						<?php echo $type_incident['nom_type']; ?>
					</td>
					<td>
						<a href="<?php echo $path; ?>administration/add_type_incident.php?action=modif&type_incident=<?php echo $type_incident['id_type_incident']; ?>"> MODIFIER </a>
					</td>
					<td>
						<a href="<?php echo $path; ?>administration/add_type_incident.php?action=delete&type_incident=<?php echo $type_incident['id_type_incident']; ?>"> SUPPRIMER </a>
					</td>
				</tr>
			<?php
				}
			?>
		</table>
	</div>
<?php
	include_once($path.'footer.php');
?>